﻿<UserControl x:Class="SMS.Views.User.ChangePassword"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
             xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk"
    xmlns:my="clr-namespace:SMS.Controls;assembly=SMS.Controls"
    d:DesignHeight="300" d:DesignWidth="400">

    <Grid x:Name="LayoutRoot">
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="Auto" />
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>
        <Grid>
            <Border 
                    BorderBrush="Black"
                    BorderThickness="1">
                <Grid Margin="5"
                      >
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition />
                        <ColumnDefinition Width="4" />
                        <ColumnDefinition />
                    </Grid.ColumnDefinitions>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="15" />
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="5" />
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="5" />
                        <RowDefinition Height="Auto" />
                        <RowDefinition Height="5" />
                        

                    </Grid.RowDefinitions>
                    <TextBlock Text="Change Password"
                               FontSize="15" FontWeight="Bold"/>
                    <TextBlock Text="Current Password"
                               Grid.Row="2" />
                    <Rectangle Grid.Row="1"
                               Style="{StaticResource SeperatorRectangle}"
                               Grid.ColumnSpan="3" />
                    <Rectangle Grid.Row="3"
                               Style="{StaticResource SeperatorRectangle}"
                               Grid.ColumnSpan="3" />
                    <Rectangle Grid.Row="5"
                               Style="{StaticResource SeperatorRectangle}"
                               Grid.ColumnSpan="3" />
                    <Rectangle Grid.Row="7"
                               Style="{StaticResource SeperatorRectangle}"
                               Grid.ColumnSpan="3" />
                   
                           
                   <PasswordBox Grid.Row="2"
                             Grid.Column="2"
                             Password="{Binding Path=CurrentPassword, Mode=TwoWay}" />

                    <TextBlock Text="New Password"
                               Grid.Row="4" />
                    <PasswordBox Grid.Row="4"
                             Grid.Column="2"
                             Password="{Binding Path=NewPassword, Mode=TwoWay}" />
                    <TextBlock Text="Confirm Password"
                               Grid.Row="6" />
                    <PasswordBox Grid.Row="6"
                             Password="{Binding Path=ConfirmNewPassword, Mode=TwoWay}"
                             Grid.Column="2" />
                </Grid>
            </Border>
        </Grid>
        <StackPanel HorizontalAlignment="Right"
                    Orientation="Horizontal"
                    Grid.Row="1">
            <Button Content="Save"
                    Command="{Binding Path=OkButtonCommand}"
                    Width="75"
                    Margin="5,0" />
            <Button Content="Cancel"
                    Width="75"
                    Command="{Binding Path=CancelCommand}" />
        </StackPanel>
        <Grid Grid.Row="3">
            <my:ErrorControl HorizontalAlignment="Left"
                             Name="errorControl1"
                             VerticalAlignment="Top" />
        </Grid>
    </Grid>
</UserControl>
